//
// Created by wkm on 2023-12-06.
//

#ifndef MYSYSTEMCLEARNING_FOUR_BIT_ADDER_H
#define MYSYSTEMCLEARNING_FOUR_BIT_ADDER_H

#include "systemc.h"

const int SIZE = 4;

SC_MODULE(four_bit_add) {
    sc_in<sc_uint<SIZE>> sha, shb;
    sc_in<bool> shcarry_in;
    sc_out<sc_uint<SIZE>> shsum;
    sc_out<bool> shcarry_out;

    void prc_four_bit_adder();

    SC_CTOR(four_bit_add) {
        SC_METHOD(prc_four_bit_adder);
        sensitive << sha << shb << shcarry_in;
    }
};

#endif //MYSYSTEMCLEARNING_FOUR_BIT_ADDER_H
